<template>
  <div style="padding: 0 15px; height: 40px; line-height: 40px; text-align: right;">
    <svg-icon
      :class="{'isActive':isActive}"
      class="hamburger"
      icon-class="expand"
      @click="toggleClick"
    />
  </div>
</template>

<script>
export default {
  name: 'Hamburger',
  props: {
    isActive: {
      type: Boolean,
      default: false
    }
  },
  methods: {
    toggleClick() {
      this.$emit('toggleClick')
    }
  }
}
</script>

<style scoped>
.hamburger {
  display: inline-block;
  vertical-align: middle;
  width: 20px;
  height: 20px;
  line-height: 40px;
  color: #ffffff;
  cursor: pointer;
  transform: rotateY(180deg);
}

.hamburger.isActive {
  transform: rotateY(0);
}
</style>
